/**
 * Coryright 2015-2020 www.eyaomall.cn
 * All rights reserved.
 * @author yuhuafeng
 * @date 2016年9月20日
 *
 */

package com.eyaomall.wxmall.controller;

import javax.servlet.http.HttpServletRequest;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import com.eyaomall.wxmall.common.helper.MemberHelper;
import com.eyaomall.wxmall.model.po.WebLog;
import com.eyaomall.wxmall.service.WebStatisticService;


/**
 * 页面数据采集
 * @author yuhuafeng
 * @date 2016-9-20
 */
@Controller
@RequestMapping("webstatistic")
public class WebStatisticCubeController {
		
	@Autowired
	private WebStatisticService webStatisticService;
	
	
	
	
	/**
	 * 查询粉丝增减详情
	 * @return
	 */
	@RequestMapping("collect")
	public @ResponseBody  void collect(WebLog log,HttpServletRequest request){
		log.setId(null);
		log.setShopId(MemberHelper.getShopId());
		log.setMemberId(MemberHelper.getId());
		log.setIp(request.getRemoteHost());
		webStatisticService.collect(log);
	}
	
	
}
